import numpy as np
from scipy import stats

data = np.array([1728.29688, 1781.9181, 1784.6099])
data = np.array([1095.557, 1251.78979, 1207.59863])
# 计算 Z-Score
z_scores = np.abs(stats.zscore(data))

# 设置阈值，剔除异常值
threshold = 1
data_cleaned = data[z_scores < threshold]
print(f"Removed {len(data) - len(data_cleaned)} outliers")

# 输出清理后的数据
print("Cleaned data:", data_cleaned)
